package com.ruoyi.web.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.web.domain.SysResources;
import com.ruoyi.web.mapper.SysResourcesMapper;
import com.ruoyi.web.service.SysResourcesService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
* @author renzhilong
* @description 针对表【sys_resources(系统资源表（包括图片、文件等）)】的数据库操作Service实现
* @createDate 2023-09-26 20:05:55
*/
@Service
public class SysResourcesServiceImpl extends ServiceImpl<SysResourcesMapper, SysResources> implements SysResourcesService {

    @Resource
    SysResourcesMapper sysResourcesMapper;

    @Override
    public int deleteFile(Long fileId) {
        return sysResourcesMapper.deleteFile(fileId);
    }

    @Override
    public String getMongoIdById(Long fileId) {
        return sysResourcesMapper.getMongoIdById(fileId);
    }

    @Override
    public SysResources getById(Long fileId) {
        return sysResourcesMapper.getById(fileId);
    }

    @Override
    public int insert(SysResources sysResources) {
        return sysResourcesMapper.insert(sysResources);
    }
}




